/*
 * $Id: HandshakeResult.java,v 1.2 2009/03/30 15:47:09 afaichun Exp $
 * 
 * Copyright (C) 2008 General Electric Company. All Rights Reserved.
 * 
 * This software is the confidential and proprietary information of the General
 * Electric Company (GE). You shall not disclose this software and shall use it
 * only in accordance with the terms of the license agreement you entered into
 * with GE.
 * 
 * GE MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE
 * SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
 * NON-INFRINGEMENT. GE SHALL NOT BE LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
 * AS A RESULT OF USING, MODIFYING, OR DISTRIBUTING THIS SOFTWARE OR ITS
 * DERIVATIVES.
 */
package com.ge.healthcare.autosc.processor.iptds.worker;

import java.util.Vector;
/**
 * 
 * @author 212042946
 *
 */
public class HandshakeResult {
	public static final String URGENT_MODE = "URGENT";
	private String mode = "UNKNOWN";
	private String scanUsn = "UNKNOWN";
    private String scanSiteName = "UNKNOWN";
    private boolean simulator = false;
    protected String dispatchService = null;
    private Vector<String> dispatchServiceArgs = new Vector<String>();

    public String getMode() {
    	return mode;
    }
    
    public void setMode(String mode) {
    	this.mode = mode;
    }
    
    public boolean isUrgentMode() {
    	return (HandshakeResult.URGENT_MODE.equalsIgnoreCase(mode)?true:false);
    }
    
    public String getScanUsn() {
		return scanUsn;
	}
	
    public void setScanUsn(String scanUsn) {
		this.scanUsn = scanUsn;
	}
	
    public String getScanSiteName() {
		return scanSiteName;
	}
	
    public void setScanSiteName(String scanSiteName) {
		this.scanSiteName = scanSiteName;
	}
	
    public boolean isSimulator() {
		return simulator;
	}
	
    public void setSimulator(boolean simulator) {
		this.simulator = simulator;
	}
	
    public String getDispatchService() {
		return dispatchService;
	}
	
    public void setDispatchService(String dispatchService) {
		this.dispatchService = dispatchService;
	}
    
	public void addDispatchArg(String arg) {
		dispatchServiceArgs.add(arg);
	}
	
	/**
	 * get dispatch argument 
	 * @param index argument number starting from 0
	 * @return
	 */
	public String getDispatchArg(int index) {
		String value = null;
		if(dispatchServiceArgs.size() > index)
			value = (String)dispatchServiceArgs.get(index);
		return value;
	}
}
